﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;

namespace UCenter.ContactFromLiveID
{
    [XmlNodeMapping(XmlNodeName = "Tags/Tag")]
    [DataContract]
    public class LiveContractGroup
    {
        public LiveContractGroup()
        {
            this.ContractIDs = new List<string>();
            this.Contracts = new List<LiveContract>();
        }

        /// <summary>
        /// Gets or sets the ID.
        /// </summary>
        /// <value>The ID.</value>
        [DataMember]
        [XmlNodeMapping(XmlNodeName = "ID")]
        public string ID { get; set; }

        /// <summary>
        /// Gets or sets the name.
        /// </summary>
        /// <value>The name.</value>
        [XmlNodeMapping(XmlNodeName = "Name")]
        [DataMember]
        public string Name { get; set; }

        /// <summary>
        /// Gets or sets the contracts.
        /// </summary>
        /// <value>The contracts.</value>
        [DataMember]
        public List<LiveContract> Contracts { get; set; }

        /// <summary>
        /// Gets or sets the contract I ds.
        /// </summary>
        /// <value>The contract I ds.</value>
        [XmlNodeMapping(XmlNodeName = "ContactIDs/ContactID/ID", IsCollection = true)]
        public List<string> ContractIDs { get; set; }
    }
}
